#pragma once

#include "WorksVector.h"


/// Manages work queues of connections
class WorkManager
{
public:
	/// Construct a WorkManager
	WorkManager();

	/// Disposes allocated resources
	~WorkManager();

	/// Enqueues request for performing a work
	void EnqueueWork(TcpConnection *connecton, ConnectionCallback work);

	/// Dequeues all requested works
	WorksVector *DequeueWorks();

private:
	/// Queue of requested works
	WorksVector *_works;
};
